package dabs;
import dabs.engine.*;
import dabs.ginterface.*;


public class BunnyAttack {
	public static void main(String args[]) throws InterruptedException {
		
		// create interface and engine
		GameEngine engine = new GameEngine();
		GameInterface gameInterface = new GameInterface(engine); // pass the engine to the interface
		
		// both of them run separately, therefore we use threads
		Thread t1 = new Thread(engine);
		Thread t2 = new Thread(gameInterface);
		
		// start them
		t1.start();
		t2.start();
		
		// wait until the interface finishes (until user types in quit)
		t2.join();
		
		// then wait until game engine closes (interface SHOULD notify the engine to close itself)
		t1.join();
	}
}
